libowfat: update to version 0.31
authorDaniel Golle <[email protected]>
Sun, 18 Jun 2017 18:53:28 +0000 (20:53 +0200)
committerDaniel Golle <[email protected]>
Sun, 18 Jun 2017 23:33:32 +0000 (01:33 +0200)
now requires host-build to provide the 'ent' build-tool which generates
entities.h for use in scan_html.

Signed-off-by: Daniel Golle <[email protected]>
libs/libowfat/Makefile
libs/libowfat/patches/001-fixbuild.patch

index 01bd25a1f697c11a4da6a7967492d7bd1fb71413..99eba1c2554e45f0c9b56595474ff67775e5980f 100644 (file)
@@ -1,26 +1,24 @@
-#
-# Copyright (C) 2010-2014 OpenWrt.org
-#
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
 #
 
 include $(TOPDIR)/rules.mk
 
-LOWFAT_VERSION=0.30
-
 PKG_NAME:=libowfat
-PKG_VERSION:=$(LOWFAT_VERSION)
+PKG_VERSION:=0.31
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
 PKG_SOURCE_URL:=http://www.fefe.de/libowfat
-PKG_MD5SUM:=f0119532ea834ce9e80afe49d7d85512
+PKG_HASH:=d1e4ac1cfccbb7dc51d77d96398e6302d229ba7538158826c84cb4254c7e8a12
 PKG_MAINTAINER:=Daniel Golle <[email protected]>
 PKG_LICENSE:=GPL-2.0
 PKG_LICENSE_FILES:=COPYING
 
+PKG_BUILD_DEPENDS += libowfat/host
+
 include $(INCLUDE_DIR)/package.mk
+include $(INCLUDE_DIR)/host-build.mk
 
 # set to 1 to enable debugging
 DEBUG=
@@ -39,7 +37,13 @@ TARGET_CFLAGS += $(FPIC)
 LOWFAT_MAKEOPTS = $(TARGET_CONFIGURE_OPTS) \
        CFLAGS="$(TARGET_CFLAGS) -I$(PKG_BUILD_DIR) -I$(STAGING_DIR)/usr/include" \
        DEBUG="$(DEBUG)" \
-       VERSION="$(LOWFAT_VERSION)" \
+       VERSION="$(PKG_VERSION)" \
+       OS="Linux"
+
+LOWFAT_HOST_MAKEOPTS = $(HOST_CONFIGURE_OPTS) \
+       CFLAGS="$(HOST_CFLAGS) -I$(HOST_BUILD_DIR) -I$(STAGING_DIR_HOSTPKG)/include" \
+       DEBUG="$(DEBUG)" \
+       VERSION="$(PKG_VERSION)" \
        OS="Linux"
 
 # work around a nasty gcc bug
@@ -51,6 +55,15 @@ define Build/Compile
        $(MAKE) -C $(PKG_BUILD_DIR) $(LOWFAT_MAKEOPTS)
 endef
 
+define Host/Compile
+       $(MAKE) -C $(HOST_BUILD_DIR) $(LOWFAT_HOST_MAKEOPTS) ent
+endef
+
+define Host/Install
+       $(INSTALL_DIR) $(STAGING_DIR_HOSTPKG)/bin
+       $(CP) $(HOST_BUILD_DIR)/ent $(STAGING_DIR_HOSTPKG)/bin/libowfat-ent
+endef
+
 define Build/InstallDev
        mkdir -p $(1)/usr/include/libowfat
        $(CP) $(PKG_BUILD_DIR)/*.h $(1)/usr/include/libowfat
@@ -58,4 +71,5 @@ define Build/InstallDev
        $(CP) $(PKG_BUILD_DIR)/*.a $(1)/usr/lib
 endef
 
+$(eval $(call HostBuild))
 $(eval $(call BuildPackage,libowfat))
index a21fcd0ee2cdc5719aa18780a9d3d8728e822741..5f4f06df35513cf99d8e2003c57f8ee6d046a116 100644 (file)
@@ -1,6 +1,6 @@
 --- a/GNUmakefile
 +++ b/GNUmakefile
-@@ -278,6 +278,8 @@ socket_accept4.o socket_accept6.o socket
+@@ -343,6 +343,8 @@ socket_accept4.o socket_accept6.o socket
  socket_local6.o socket_recv4.o socket_recv6.o socket_remote4.o \
  socket_remote6.o: havesl.h
  
@@ -9,3 +9,11 @@
  dns_nd6.o fmt_xlong.o scan_xlong.o fmt_ip6_flat.o $(TEXTCODE_OBJS): haveinline.h
  
  iob_send.o scan_ip6if.o: havealloca.h
+@@ -372,6 +374,6 @@ update:
+       dl -n http://www.w3.org/TR/html5/entities.json
+ entities.h: entities.json ent
+-      ./ent
++      libowfat-ent
+ scan_html.o: entities.h